package com.zoffy.wmsbackend.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.zoffy.wmsbackend.model.dto.transfer.TransferOrderDto;
import com.zoffy.wmsbackend.model.entity.StockTransferOrder;
import com.zoffy.wmsbackend.model.vo.transfer.TransferDetailVo;
import com.zoffy.wmsbackend.model.vo.transfer.TransferOrderVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface TransferOrderMapper extends BaseMapper<StockTransferOrder> {
    /**
     * 分页查询调拨单列表
     * @param page 分页信息
     * @param dto 查询参数
     * @return 分页查询结果
     */
    Page<TransferOrderVo> listTransferOrderVoByPage(Page<TransferOrderVo> page, @Param("dto") TransferOrderDto dto);
    // 根据 ID 获取调拨单基本信息
    TransferOrderVo getTransferVoById(@Param("id") Long id);

    // 根据 ID 获取调拨单详细信息
    List<TransferDetailVo> getDetailsById(@Param("id") Long id);
}
